/*
 * File    : /src/api/template/process.js
 * Time    : 2021-09-23 12:28:59
 * Author  : Gray Snail
 * Version : 1.0
 * Contact : shtao2011@sina.com
 * License : Copyright (c) 2021 Gray Snail
 * Desc    : None
 */

import request from '@/utils/request'

// 查询流程模板列表
export function listProcess(query) {
  return request({
    url: '/template/process/list',
    method: 'get',
    params: query,
  })
}

// 查询流程模板详细
export function getProcess(id) {
  return request({
    url: '/template/process/' + id,
    method: 'get',
  })
}

// 新增流程模板
export function addProcess(data) {
  return request({
    url: '/template/process',
    method: 'post',
    data: data,
  })
}

// 修改流程模板
export function updateProcess(data) {
  return request({
    url: '/template/process',
    method: 'put',
    data: data,
  })
}

// 删除流程模板
export function delProcess(id) {
  return request({
    url: '/template/process/' + id,
    method: 'delete',
  })
}

// 导出流程模板
export function exportProcess(query) {
  return request({
    url: '/template/process/export',
    method: 'get',
    params: query,
  })
}
